﻿namespace EFS.RC.CC.SAL.Loggers.Messages
{
	public class Message
	{
		/// <summary>
		/// Constructor
		/// </summary>
		public Message(System.Guid? conversationGuid, System.String method, System.String context)	
		{
			// set default
			Occurred = System.DateTime.Now;
			ConversationGuid = conversationGuid;
			Method = method;
			Context = context;

			// add to list
			EFS.RC.CC.SAL.Loggers.Logger.Instance.Add(this);
		}

		/// <summary>
		/// Constructor
		/// </summary>
		public Message(System.Guid? conversationGuid, System.String method, System.String detail, System.String context)
		{
			// set default
			Occurred = System.DateTime.Now;
			ConversationGuid = conversationGuid;
			Method = method;
			Detail = detail;
			Context = context;

			// add to list
			EFS.RC.CC.SAL.Loggers.Logger.Instance.Add(this);
		}

		/// <summary>
		/// Property Occurred: Get, Set
		public System.DateTime Occurred { get; private set; }

		/// Property Occurred: Get, Set
		public System.Guid? ConversationGuid { get; private set; }

		/// Property Method: Get, Set
		public System.String Method { get; private set; }

		/// Property Context: Get, Set
		public System.String Context { get; private set; }

		/// Property Detail: Get, Set
		public System.String Detail { get; private set; }
	}
}